package pp.gateway.domain.user.aggregation.entity.loginstrategy;

import lombok.Getter;
import lombok.extern.slf4j.Slf4j;
import pp.infrastructure.util.stringhelper.StringHelper;

@Getter
@Slf4j
public class AccountLoginStrategy {

    private final String account;
    private final String pwd;
    private final String name;
    private final String img;


    public AccountLoginStrategy(String account, String pwd, String name, String img) {
        this.account = account;
        this.pwd = pwd;
        this.name = name;
        this.img = img;
    }

    public boolean verifyPwd(String pwd) {
        return this.pwd.equals(StringHelper.encrypt(pwd));
    }
}
